#include <iostream>

using namespace std;

#include "lit/elf/elfFile.h"
#include "lit/elf/linker.h"

int main() {
    std::string fileName = "/home/zengao/CLionProjects/DspNASM/lit/a.o";
    std::string fileOut = "/home/zengao/CLionProjects/DspNASM/lit/a.out";
    auto linker = make_shared<Linker>();
    linker->addElf(fileName.c_str());
    linker->allocAddr();
    linker->collectInfo();
    linker->symValid();
    linker->symParser();
    linker->relocate();
    linker->assemExe();
    linker->exportElf(fileOut.c_str());
    return 0;
}